/* 2014/10/24 */
package com.cosmos.quartz.control.Db;

import java.sql.Timestamp;

import com.cosmos.quartz.control.ControlRequest;

public class DbControlRequest {

	private int id;	
	private String job;	
	private String operation;
	private Timestamp createdTime;
	private String agent;
	
	public DbControlRequest() {
		
	}
	
	public DbControlRequest(ControlRequest request) {
		job = request.getJobName();
		operation = request.getOperation();
	}
	
	public ControlRequest toBaseRequest() {
		ControlRequest request = new ControlRequest();
		request.setJobName(job);
		request.setOperation(operation);
		return request;
	}
	
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}
	
	public String getJob() {
		return job;
	}
	public void setJob(String job) {
		this.job = job;
	}
	
	public String getOperation() {
		return operation;
	}
	public void setOperation(String operation) {
		this.operation = operation;
	}
	
	public Timestamp getCreatedTime() {
		return createdTime;
	}
	public void setCreatedTime(Timestamp createdTime) {
		this.createdTime = createdTime;
	}
	
	public String getAgent() {
		return agent;
	}
	public void setAgent(String agent) {
		this.agent = agent;
	}
	
}
